/*
*
* This file is part of xVideoServiceThief,
* an open-source cross-platform Video service download
*
* Copyright (C) 2007 - 2014 Xesc & Technology
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with xVideoServiceThief. If not, see <http://www.gnu.org/licenses/>.
*
* Contact e-mail: Xesc <xeskuu.xvst@gmail.com>
* Program URL   : http://xviservicethief.sourceforge.net/
*
*/

function RegistVideoService()
{
	this.version = "1.0.0";
	this.minVersion = "2.0.0a";
	this.author = "crapmaster & Xesc & Technology 2014";
	this.website = "http://www.totallyupyours.com";
	this.ID = "totallyupyours.com";
	this.caption = "Totally Up Yours";
	this.adultContent = false;
	this.musicSite = false;
}

function getVideoInformation(url)
{
	// video information
	var result = new VideoDefinition();

	// download webpage
	var http = new Http();
	var html = http.downloadWebpage(url);

	// get video title
        var tmp = copyBetween(html, '<div id="content">', '<div id="media">');
	result.title = copyBetween(tmp, '<h1>', '</h1>');

	// get the video  url
	var videoUrl = copyBetween(html, "?vid=", "'");

	result.URL=cleanUrl(videoUrl);

	// return the video information
	return result;
}

function getVideoServiceIcon()
{
	return new Array(
		0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,0x44,0x52,
		0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x10,0x08,0x06,0x00,0x00,0x00,0x1f,0xf3,0xff,
		0x61,0x00,0x00,0x02,0x8a,0x49,0x44,0x41,0x54,0x78,0xda,0x6d,0x93,0x6b,0x48,0x53,
		0x61,0x18,0xc7,0x4f,0xb0,0xe9,0x3a,0x4b,0xe7,0x96,0x9b,0x97,0x79,0xe6,0xbc,0xad,
		0x1a,0x47,0x05,0x53,0x1b,0x2a,0xb9,0x0c,0x9b,0x52,0x28,0x74,0x01,0x95,0x51,0x5f,
		0x0a,0xd4,0x6c,0xeb,0x8b,0x09,0x5a,0x64,0x06,0x65,0x57,0x4a,0xc8,0x62,0x43,0xd2,
		0xa0,0xfc,0x12,0x15,0x56,0xd2,0x87,0xc2,0xb0,0x15,0x39,0xd3,0x52,0x2a,0x09,0x51,
		0x8c,0xcc,0x40,0xfb,0x90,0x17,0x82,0x4d,0xb7,0x7f,0xef,0x39,0xa3,0x17,0xce,0xea,
		0x81,0x1f,0xfc,0x79,0x2e,0xff,0xf7,0x70,0x78,0x1e,0x86,0x65,0x59,0xc8,0x64,0x32,
		0x4a,0x74,0x84,0x1c,0x55,0x7a,0x1d,0x3a,0xf9,0x0c,0x3c,0xce,0xe5,0xf1,0x24,0x8f,
		0x87,0x2b,0xd3,0x84,0x43,0x5c,0x3c,0x34,0x91,0x11,0x92,0x5e,0x61,0x96,0x11,0x04,
		0xc3,0x30,0x22,0x7b,0x62,0xd5,0x18,0xca,0xcf,0xc4,0xd7,0x8a,0x52,0xcc,0x94,0x15,
		0x63,0xba,0x28,0x47,0xc2,0x7b,0x4b,0x16,0x6a,0xe2,0x63,0xb1,0x2e,0xd4,0x2f,0x9a,
		0x50,0x83,0x7a,0x7d,0x1c,0x3e,0x5b,0xb2,0x31,0x41,0x98,0xb6,0xef,0xc7,0x64,0x99,
		0x55,0xd0,0xff,0xa5,0xc5,0xa8,0x17,0x4d,0xa8,0x81,0x4d,0xad,0xc2,0x87,0x1c,0x1e,
		0x63,0x5b,0x43,0x7c,0x2c,0x2e,0xc0,0x54,0xdd,0x61,0x8c,0xd1,0xdc,0xbf,0x54,0x6b,
		0x37,0x86,0x0c,0x94,0x72,0x19,0xfa,0xcd,0x26,0x0c,0x67,0x9b,0x45,0x46,0x2c,0xb9,
		0x98,0x69,0x3d,0x85,0xa9,0xe6,0x26,0x4c,0x3a,0x8e,0xd2,0x7c,0x38,0x2f,0xf9,0xcd,
		0xd0,0x92,0x7f,0xc2,0xec,0xd6,0xa8,0xf1,0x3a,0x9b,0xc7,0xbb,0x5d,0x3b,0x31,0x5c,
		0x52,0x8c,0x89,0xe3,0x0e,0x08,0x31,0xdf,0xf7,0x08,0x3f,0x7a,0xef,0x61,0xdc,0x5e,
		0x8d,0x2f,0x4d,0x8d,0x98,0x70,0x36,0xe0,0x53,0xed,0x11,0x8c,0x1f,0xb4,0xc3,0x63,
		0xde,0x24,0x62,0xd7,0x69,0xc1,0x34,0x27,0x26,0x62,0x20,0x2b,0x13,0x6f,0x4a,0x4b,
		0xe1,0xdd,0xb7,0x17,0x63,0x75,0xb5,0x98,0x71,0xbb,0x20,0x44,0x60,0xd5,0x0f,0xdf,
		0xc2,0x02,0x7e,0x8d,0x8e,0xe2,0x5b,0x4f,0x0f,0xbc,0x95,0x15,0x78,0x9e,0x91,0x4e,
		0xb9,0x6c,0xe0,0xc0,0x5c,0xe1,0x38,0xf4,0xa7,0xa6,0x52,0x06,0xac,0x56,0x4c,0x77,
		0x75,0x21,0xe0,0xf7,0x23,0x3c,0x82,0x81,0x00,0x7e,0x7a,0x3c,0x18,0xb4,0xd9,0xc4,
		0xde,0xbb,0x46,0x23,0x98,0xf6,0x24,0x3d,0x1e,0x12,0xf1,0x97,0x07,0x84,0x61,0xa7,
		0x53,0x62,0x10,0x1e,0xab,0xcb,0xcb,0x78,0x56,0x54,0x88,0x6e,0x83,0x01,0x8c,0x43,
		0xab,0x43,0x6f,0x12,0x27,0xc1,0xdb,0x78,0x02,0xab,0x2b,0x2b,0x92,0x21,0xdf,0xe2,
		0x22,0xd6,0x7c,0x3e,0x04,0x83,0x41,0x04,0xd6,0xd6,0xf0,0x74,0x47,0x09,0x4e,0xc7,
		0x27,0x80,0xb1,0x6e,0x88,0x42,0x77,0x82,0x9e,0x72,0x27,0x39,0x05,0x83,0xc7,0x1c,
		0xf8,0x3d,0x3f,0x4f,0x87,0x97,0x67,0x67,0x71,0x3f,0xdf,0x82,0x3e,0x5b,0x39,0xbc,
		0x67,0xda,0xf0,0xb6,0xe5,0x24,0x7a,0xc8,0x43,0x95,0xaa,0x18,0x30,0x4a,0x99,0x0c,
		0x97,0xb4,0x71,0xb8,0x15,0x97,0x00,0x97,0x9e,0xc3,0x8b,0xfa,0x06,0xb8,0xb9,0x64,
		0xcc,0x7a,0x3c,0xd4,0x60,0xe8,0xdc,0x79,0xa1,0x4e,0x71,0x25,0x19,0xd0,0xa1,0x23,
		0xab,0x2d,0x97,0x87,0x16,0x29,0x5f,0xa1,0xc0,0x35,0x62,0xd2,0x41,0xbe,0xe0,0x46,
		0x72,0x8a,0xa8,0x5f,0xb5,0x9d,0xa5,0x06,0x23,0x9d,0x37,0x71,0x3b,0x37,0x4f,0xc8,
		0x53,0x4a,0x58,0x56,0xba,0xca,0xe5,0xac,0x12,0xed,0x9a,0x58,0xca,0xf5,0x74,0x13,
		0x96,0xe6,0xe6,0xb0,0xf4,0x7d,0x0e,0x6e,0x4b,0x01,0xba,0x8a,0xb6,0xd3,0xda,0x01,
		0x65,0x14,0x5d,0x65,0xc9,0x31,0xe5,0x44,0x44,0xa2,0x49,0xa5,0x46,0x6b,0x8c,0x46,
		0xe4,0x62,0x5a,0x06,0x2e,0xa4,0xa4,0x89,0x5c,0xdd,0xc2,0xa3,0x59,0xa5,0x41,0x61,
		0xa4,0x42,0x7a,0x4c,0xe1,0xe7,0xac,0x24,0x6c,0x5b,0xcf,0xa2,0x2a,0x4a,0x05,0x47,
		0x74,0x0c,0x9c,0x84,0x1a,0xa2,0x0b,0x49,0x5f,0x34,0xa9,0x85,0x9f,0xf3,0x1f,0x82,
		0x68,0x23,0xc9,0xba,0xf3,0x8c,0xeb,0x00,0x00,0x00,0x00,0x49,0x45,0x4e,0x44,0xae,
		0x42,0x60,0x82);
}